package com.celebracion.user;

import com.celebracion.R;
import com.celebracion.R.id;
import com.celebracion.R.layout;
import com.celebracion.util.DBUtil;
import com.celebracion.util.SystemUiHider;

import android.annotation.TargetApi;
import android.app.Activity;
import android.os.Build;
import android.os.Bundle;
import android.os.Handler;
import android.view.MotionEvent;
import android.view.View;
import android.view.Window;
import android.widget.EditText;

/**
 * An example full-screen activity that shows and hides the system UI (i.e.
 * status bar and navigation/system bar) with user interaction.
 * 
 * @see SystemUiHider
 */
public class CrearEventoActivity extends Activity {


	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		requestWindowFeature(Window.FEATURE_NO_TITLE);
		setContentView(R.layout.activity_crear_evento);

		
	}
	
	public void guardar(View view){
		String evento=((EditText)findViewById(R.id.etNombreEvento)).getText().toString();
		String direccion=((EditText)findViewById(R.id.etDireccionEnvio)).getText().toString();
		DBUtil.getInstance(this.getBaseContext()).insert(evento, direccion);
		this.finish();
	}
	
	public void cancelar(View view){
		this.finish();
	}
	
}
